var t = require;
var e = module;
var o = exports;
var i, n = this && this.__extends || (i = function(t, e) {
    return (i = Object.setPrototypeOf || {
        __proto__: []
    }
    instanceof Array &&
    function(t, e) {
        t.__proto__ = e
    } ||
    function(t, e) {
        for (var o in e) Object.prototype.hasOwnProperty.call(e, o) && (t[o] = e[o])
    })(t, e)
},
function(t, e) {
    function o() {
        this.constructor = t
    }
    i(t, e),
    t.prototype = null === e ? Object.create(e) : (o.prototype = e.prototype, new o)
}),
a = this && this.__decorate ||
function(t, e, o, i) {
    var n, a = arguments.length,
    r = a < 3 ? e: null === i ? i = Object.getOwnPropertyDescriptor(e, o) : i;
    if ("object" == typeof Reflect && "function" == typeof Reflect.decorate) r = Reflect.decorate(t, e, o, i);
    else for (var s = t.length - 1; s >= 0; s--)(n = t[s]) && (r = (a < 3 ? n(r) : a > 3 ? n(e, o, r) : n(e, o)) || r);
    return a > 3 && r && Object.defineProperty(e, o, r),
    r
};
Object.defineProperty(o, "__esModule", {
    value: !0
});
var r = t("GameConstant"),
s = t("GameLogic"),
l = t("GameManage"),
c = cc._decorator,
d = c.ccclass,
h = c.property,
p = function(t) {
    function e() {
        var e = null !== t && t.apply(this, arguments) || this;
        return e.gameScene = null,
        e._gameConstrol = null,
        e._gameLogic = new s.GameLogic,
        e
    }
    return n(e, t),
    e.prototype.onLoad = function() {
        this._gameConstrol = this.gameScene.getComponent(l.default)
    },
    e.prototype.init = function(t) {
        this._gameConstrol = t
    },
    e.prototype.onCollisionEnter = function(t) {
        if (t.node.group == r.Collide_Group_Car.wheel || t.node.group == r.Collide_Group_Car.body) {
            var e = this._gameLogic.getColliderCarTag(t.tag);
            this.onShowAirShop(e)
        }
    },
    e.prototype.onShowAirShop = function(t) {
        switch (t) {
            case r.Physics_Car_Tag.Left:
                this._gameConstrol._airShipLeft.playShowIn();
            break;
            case r.Physics_Car_Tag.Right:
                this._gameConstrol._airShipRight.playShowIn();
        }
    },
    a([h(cc.Node)], e.prototype, "gameScene", void 0),
    a([d], e)
} (cc.Component);
o.default = p